Population Health Management Process API - Implementation Template
Setup guide
Prerequisites
Dependent Applications
This application depends on the following applications to convert messages into FHIR format.
- HL7 v2 to FHIR System API
- C-CDA to FHIR System API
- X12 to FHIR System API
MQ Queue Setup
This application uses Anypoint MQ to manage the queues of messages to process. There are 3 queues that need to be created in Anypoint MQ, one for HL7, one for CCDA, and one for X12 messages. The applications assumes that FIFO queues are used to preserve message order, however you can choose the queue that works for your use case.
Setup guide
Importing Templates into Anypoint Studio
- In Studio, click the Exchange X icon in the upper left of the taskbar.
- Log in with your Anypoint Platform credentials.
- Search for the template.
- Click Open.
Running Templates in Anypoint Studio
After you import your template into Studio, follow these configuration steps to run it.
Common Configuration
mule.env
- sets the environment where the application is to be deployed. It should be configured inconfig-<mule.env>.yaml
file. For a studio deployment, the recommended mule.env value islocal
.mule.key
- sets the encryption password to be used for encrypting secure properties. Update as needed.api.baseurl
- sets the base url of the api. Replace/override as needed when deploying to any environment. It should be configured inconfig-<mule.env>.yaml
file. Default value ishttps://localhost:8082/api
, whenmule.env
islocal
.api.autodiscoveryID
should be configured inconfig-<mule.env>.yaml
file.
Please refer to the attached link on how to secure the configuration properties.
HTTPS Configuration
https.host
— sets the service host interface. It should be configured inconfig-<mule.env>.yaml
file. (Defaults to 0.0.0.0 for all interfaces).https.port
— sets the HTTPS service port number. It should be configured inconfig-<mule.env>.yaml
file. (Default 8082).- TLS Configuration - Keystore properties setup:
keystore.alias
- sets the alias to the keystore. It should be configured inconfig-<mule.env>.yaml
file.keystore.path
- sets the path to the key file. Key should be availabe in /src/main/resources/keystore. It should be configured inconfig-<mule.env>.yaml
file.keystore.keypass
— sets keystore keypass to support HTTPS operation. It should be encrypted and configured inconfig-secured-<mule.env>.yaml
file.keystore.password
— sets keystore password to support HTTPS operation. It should be encrypted and configured inconfig-secured-<mule.env>.yaml
file.
Please refer to the attached link on how to generate the Keystore.
Population Health Application Configuration
The application requires a few things to be configured such as Anypoint MQ and external services connection information. Configure them in the properties file located in the config/properties
folder.
Anypoint MQ
anypoint-mq.server-url
should be configured inconfig-<mule.env>.yaml
file. The Anypoint MQ server URL.anypoint-mq.client-id
should be configured inconfig-<mule.env>.yaml
file. Your Anypoint MQ client ID.anypoint-mq.hl7v2-queue-name
should be configured inconfig-<mule.env>.yaml
file. The HL7 queue name in Anypoint MQ.anypoint-mq.x12-queue-name
should be configured inconfig-<mule.env>.yaml
file. The X12 queue name in Anypoint MQ.anypoint-mq.ccda-queue-name
should be configured inconfig-<mule.env>.yaml
file. The CCDA queue name in Anypoint MQ.anypoint-mq.client-secret
should be configured inconfig-<mule.env>.yaml
file. Your Anypoint MQ client secret.
HL7 v2 to FHIR System API
hl7v2-sys-api.host
should be configured inconfig-<mule.env>.yaml
file. The API host.hl7v2-sys-api.port
should be configured inconfig-<mule.env>.yaml
file. The API port.hl7v2-sys-api.basepath
should be configured inconfig-<mule.env>.yaml
file. The API base path.hl7v2-sys-api.responseTimeout
should be configured inconfig-<mule.env>.yaml
file. The connection response timeout.hl7v2-sys-api.reconnection.frequency
should be configured inconfig-<mule.env>.yaml
file. The reconnection frequency.hl7v2-sys-api.reconnection.attempts
should be configured inconfig-<mule.env>.yaml
file. The reconnection attempts.hl7v2-sys-api.clientid
should be configured inconfig-<mule.env>.yaml
file. The API client ID.hl7v2-sys-api.clientsecret
should be configured inconfig-<mule.env>.yaml
file. The API client secret.
X12 to FHIR System API
x12-sys-api.host
should be configured inconfig-<mule.env>.yaml
file. The API host.x12-sys-api.port
should be configured inconfig-<mule.env>.yaml
file. The API port.x12-sys-api.basepath
should be configured inconfig-<mule.env>.yaml
file. The API base path.x12-sys-api.responseTimeout
should be configured inconfig-<mule.env>.yaml
file. The connection response timeout.x12-sys-api.reconnection.frequency
should be configured inconfig-<mule.env>.yaml
file. The reconnection frequency.x12-sys-api.reconnection.attempts
should be configured inconfig-<mule.env>.yaml
file. The reconnection attempts.x12-sys-api.clientid
should be configured inconfig-<mule.env>.yaml
file. The API client ID.x12-sys-api.clientsecret
should be configured inconfig-<mule.env>.yaml
file. The API client secret.
C-CDA to FHIR System API
ccda-sys-api.host
should be configured inconfig-<mule.env>.yaml
file. The API host.ccda-sys-api.port
should be configured inconfig-<mule.env>.yaml
file. The API port.ccda-sys-api.basepath
should be configured inconfig-<mule.env>.yaml
file. The API base path.ccda-sys-api.responseTimeout
should be configured inconfig-<mule.env>.yaml
file. The connection response timeout.ccda-sys-api.reconnection.frequency
should be configured inconfig-<mule.env>.yaml
file. The reconnection frequency.ccda-sys-api.reconnection.attempts
should be configured inconfig-<mule.env>.yaml
file. The reconnection attempts.ccda-sys-api.clientid
should be configured inconfig-<mule.env>.yaml
file. The API client ID.ccda-sys-api.clientsecret
should be configured inconfig-<mule.env>.yaml
file. The API client secret.
AWS HealthLake System API
healthlake-sys-api.host
should be configured inconfig-<mule.env>.yaml
file. The API host.healthlake-sys-api.port
should be configured inconfig-<mule.env>.yaml
file. The API port.healthlake-sys-api.basepath
should be configured inconfig-<mule.env>.yaml
file. The API base path.healthlake-sys-api.responseTimeout
should be configured inconfig-<mule.env>.yaml
file. The connection response timeout.healthlake-sys-api.reconnection.frequency
should be configured inconfig-<mule.env>.yaml
file. The reconnection frequency.healthlake-sys-api.reconnection.attempts
should be configured inconfig-<mule.env>.yaml
file. The reconnection attempts.healthlake-sys-api.clientid
should be configured inconfig-<mule.env>.yaml
file. The API client ID.healthlake-sys-api.clientsecret
should be configured inconfig-<mule.env>.yaml
file. The API client secret.
Run the application
- Right-click the template project folder.
- Hover your mouse over 'Run as'.
- Click Mule Application (configure).
- Inside the dialog, select Environment and set the variable
mule.env
to the appropriate value (dev or local). - Inside the dialog, select Environment and set the variable key to the property encryption key that you used to encrypt your secure properties.
- Click Run.
Deployment instructions for CloudHub using provided scripts
Ensure the Maven profile CloudHub-DEV
has been properly configured in your settings.xml
file. Reference can be found by downloading the Accelerator Setup Guide asset. Additional instructions are available in Accelerator Setup Guide - Configuring the Accelerator Build
section.
Update the config-<env>.yaml
properties appropriately and then use one of the following scripts to deploy the application to CloudHub:
- packageDeploy.sh or deployOnly.sh (Mac/Linux).
- packageDeploy.cmd or deployOnly.cmd (Windows).
Test the template
- Use Advanced Rest Client or Postman to send a request over HTTPS. The template includes a Postman collection in the
src/test/resources
folder. Update the collection variable(s) after successful import.